﻿// <copyright file="AnalyticsException.cs" company="Microsoft Corporation">
// Copyright (c) 2009 Microsoft Corporation All Rights Reserved
// </copyright>
// <author>Michael S. Scherotter</author>
// <email>mischero@microsoft.com</email>
// <date>2010-01-21</date>
// <summary>AnalyticsException class definition</summary>

namespace Microsoft.WebAnalytics
{
    using System;
#if !SILVERLIGHT
    using System.Runtime.Serialization;
#endif

    /// <summary>
    /// Analytics Exception
    /// </summary>
#if !SILVERLIGHT
    [Serializable]
#endif
    public class AnalyticsException : Exception
    {
        /// <summary>
        /// Initializes a new instance of the AnalyticsException class.
        /// </summary>
        public AnalyticsException()
        {
        }

        /// <summary>
        /// Initializes a new instance of the AnalyticsException class.
        /// </summary>
        /// <param name="message">the error message</param>
        public AnalyticsException(string message) :
            base(message)
        {
        }

        /// <summary>
        /// Initializes a new instance of the AnalyticsException class.
        /// </summary>
        /// <param name="message">the error message</param>
        /// <param name="innerException">the inner exception</param>
        public AnalyticsException(string message, Exception innerException) :
            base(message, innerException)
        {
        }

#if !SILVERLIGHT
        /// <summary>
        /// Initializes a new instance of the AnalyticsException class.
        /// </summary>
        /// <param name="info">the serialization information</param>
        /// <param name="context">the streaming context</param>
        protected AnalyticsException(SerializationInfo info, StreamingContext context) :
            base(info, context)
        {
        }
#endif
    }
}
